<%-- 
    Document   : login
    Created on : Jul 3, 2012, 2:02:17 PM
    Author     : MTolstykh
--%>

<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<script type="text/javascript">
    require([
        "dijit/form/ValidationTextBox", 
        "dojox/validate/web",
        "dijit/form/CheckBox",
        "dijit/form/Form",
        "dijit/form/Button",
        "dojo/parser", 
        "dojo/domReady!"
    ]);
</script>

<html>
    <head>
        <title><spring:message code="login.title"/></title>
    </head>
    <body class="claro">
        <div id="loginDiv" class="loginPageClass" align="center" 
             style="border: 5px double buttonface;
             margin: 100px; margin-left: 500px; margin-right: 500px;
             padding: 10px;">
            <form:form action="j_spring_security_check" method="post" dojoType="dijit.form.Form">
                <table>
                    <tr>
                        <td>
                            <label for="j_username"><spring:message code="login.username"/></label>
                        </td>
                        <td>
                            <input id="j_username" name="j_username" type="text" size="20" maxlength="50"
                                   data-dojo-type="dijit.form.ValidationTextBox"
                                   data-dojo-props="required:true"/>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label for="j_password"><spring:message code="login.password"/> </label>
                        </td>
                        <td>
                            <input type="password" id="j_password" name="j_password" size="20" maxlength="50"
                                   data-dojo-type="dijit.form.ValidationTextBox"
                                   data-dojo-props="required:true"/>
                        </td>
                    </tr>
                    <tr>
                        <td></td>
                        <td>
                            <input id="_spring_security_remember_me" name="_spring_security_remember_me"
                                   data-dojo-type="dijit.form.CheckBox"/>
                            <label for="_spring_security_remember_me">
                                <spring:message code="login.remember.me"/>
                            </label>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <button data-dojo-type="dijit.form.Button" type="submit">
                                <spring:message code="login.login"/>
                            </button>
                        </td>
                        <td>
                            <button data-dojo-type="dijit.form.Button" type="reset">
                                <spring:message code="login.reset"/>
                            </button>
                        </td>
                    </tr>
                </table>
            </form:form>
        </div>
    </body>
</html>